///**
// * author      : dormi330
// * date        : 2018/7/17
// * description : TODO
// */
//
//package com.deep.trade.adaptor.required.mq.rabbitmq;
//
//
//import org.springframework.amqp.rabbit.connection.CachingConnectionFactory;
//import org.springframework.amqp.rabbit.connection.ConnectionFactory;
//import org.springframework.amqp.rabbit.core.RabbitTemplate;
//import org.springframework.context.annotation.Bean;
//import org.springframework.context.annotation.Configuration;
//
//
//@Configuration
//public class RabbitmqConfig {
//
//    /** 配置链接信息 */
//    @Bean
//    public ConnectionFactory connectionFactory() {
//        CachingConnectionFactory connectionFactory = new CachingConnectionFactory("127.0.0.1", 5672);
//        connectionFactory.setUsername("app_user");
//        connectionFactory.setPassword("gmc123");
//        connectionFactory.setVirtualHost("/");
//        connectionFactory.setPublisherConfirms(true); // 必须要设置
//        return connectionFactory;
//    }
//
//    @Bean
//    public RabbitTemplate amqpTemplate() {
//        return new RabbitTemplate(connectionFactory());
//    }
//
//}